import request from '@/utils/request'

// 查看区域列表/parking/area/list
export function getAreaListAPI(params) {
  return request({
    url: '/parking/area/list',
    params
  })
}

// 添加区域/parking/area
export function addAreaAPI(data) {
  return request({
    url: '/parking/area',
    method: 'post',
    data
  })
}

// 关联区域下拉列表/parking/area/dropList
export function getAreaDropListAPI() {
  return request({
    url: '/parking/area/dropList'
  })
}

// 编辑区域/parking/area
export function editAreaAPI(data) {
  return request({
    url: '/parking/area',
    method: 'put',
    data
  })
}

// 删除区域/parking/area/{id}
export function deleteAreaAPI(id) {
  return request({
    url: '/parking/area/' + id,
    method: 'delete'
  })
}
